#include <iostream>
#include <string>

using namespace std;

int main()
{
	string input;
	int i;
	
	cout << "Enter words (to stop, type the word done):\n";
	cin >> input;
	
	while(input != "done")					// string compare
	{
		i++;
		cin >> input;
	}
	
	cout << "you have inputed: " << i << " words" << endl;
	
	return 0;
}
